/**
* Created by Choisaaaa on 2018/4/25.
*/

var _mm = require("util/mm.js");

var _payment= {
    //1.根据订单号获取支付信息
    getPaymentInfo : function(orderNumber,resolve, reject){
        _mm.request({
            url     : _mm.getServerUrl('/pay/pay.do'),
            data : {
                orderNo : orderNumber
            },
            method : "get",
            success : resolve,
            error   : reject
        });
    },
    // 获取订单状态
    getPaymentStatus : function(orderNumber, resolve, reject){
        _mm.request({
            url     : _mm.getServerUrl('/pay/query_order_pay_status.do'),
            data    : {
                orderNo : orderNumber
            },
            success : resolve,
            error   : reject
        });
    }




}

module.exports = _payment;